package com.keba.lamp.complaint.entity;

import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableName;
import com.baomidou.mybatisplus.annotation.Version;
import com.keba.basic.base.entity.Entity;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.NoArgsConstructor;
import lombok.ToString;
import lombok.experimental.Accessors;

import java.time.LocalDate;

import static com.baomidou.mybatisplus.annotation.SqlCondition.EQUAL;
import static com.keba.lamp.model.constant.Condition.LIKE;


/**
 * <p>
 * 实体类
 * 代理人信息
 * </p>
 *
 * @author chaowu.wang
 * @date 2025-09-13 18:19:51
 */
@Data
@NoArgsConstructor
@AllArgsConstructor
@ToString(callSuper = true)
@Accessors(chain = true)
@EqualsAndHashCode(callSuper = true)
@Builder
@TableName("ss_agent")
public class Agent extends Entity<Long> {
    private static final long serialVersionUID = 1L;

    /**
     * 乐观锁
     */
    @TableField(value = "revision", condition = EQUAL)
    @Version
    private Integer revision;
    /**
     * 是否删除，0-未删除，1-删除
     */
    @TableField(value = "is_del", condition = EQUAL)
    private Integer isDel;
    /**
     * 类型，0-原告代理人 ，1-被告代理人
     */
    @TableField(value = "type", condition = EQUAL)
    private Integer type;
    /**
     * 证件号/营业执照号码
     */
    @TableField(value = "id_card", condition = LIKE)
    private String idCard;
    /**
     * 证件背面图片地址/营业执照照片
     */
    @TableField(value = "id_card_back_url", condition = LIKE)
    private String idCardBackUrl;
    /**
     * 证件正面图片地址
     */
    @TableField(value = "id_card_front_url", condition = LIKE)
    private String idCardFrontUrl;
    /**
     * 姓名/公司名称
     */
    @TableField(value = "name", condition = LIKE)
    private String name;
    /**
     * 性别;[1-男 2-女 3-未知]
     * @Echo(api = EchoApi.DICTIONARY_ITEM_FEIGN_CLASS, dictType = EchoDictType.Global.SEX)
     */
    @TableField(value = "sex", condition = LIKE)
    private String sex;
    /**
     * 民族;[01-汉族 99-其他]@Echo(api = EchoApi.DICTIONARY_ITEM_FEIGN_CLASS, dictType = EchoDictType.Global.NATION)
     */
    @TableField(value = "nation", condition = LIKE)
    private String nation;
    /**
     * 地址
     */
    @TableField(value = "address", condition = LIKE)
    private String address;
    /**
     * 电话号码
     */
    @TableField(value = "mobile", condition = LIKE)
    private String mobile;
    /**
     * 案子id
     */
    @TableField(value = "case_id", condition = EQUAL)
    private Long caseId;
    /**
     * 租户id
     */
    @TableField(value = "tenant_id", condition = EQUAL)
    private Long tenantId;
    /**
     * 出生日期
     */
    @TableField(value = "birth_date", condition = EQUAL)
    private LocalDate birthDate;
    /**
     * 国别(0：中国)
     */
    @TableField(value = "country", condition = EQUAL)
    private Integer country;
    /**
     * 证件类型（0 ，身份证，1 社会信用代码证）
     */
    @TableField(value = "id_type", condition = EQUAL)
    private Integer idType;
    /**
     * 固定电话
     */
    @TableField(value = "fixed_tel", condition = LIKE)
    private String fixedTel;

    /**
     * 代理人汇总信息
     */
    @TableField(value = "summarize_info", condition = LIKE)
    private String summarizeInfo;


}
